// pages/qualifying/paihang/paihang.js
Page({

  /**
   * 页面的初始数据
   */
  data: {
    showTit: true,
    regionArr: [
      {
        rankNum: 1,
        headImg: '../../../images/user_img.png',
        nickname: '沉香',
        userfrom: '厦门',
        userLevelName: '知识进士',
        userLevelImg: '../../../images/paihang_levelImg1.png',
        userStart: 10
      },
      {
        rankNum: 2,
        headImg: '../../../images/user_img.png',
        nickname: '沉木',
        userfrom: '福州',
        userLevelName: '知识进士',
        userLevelImg: '../../../images/paihang_levelImg1.png',
        userStart: 9
      },
      {
        rankNum: 3,
        headImg: '../../../images/user_img.png',
        nickname: '沉海',
        userfrom: '泉州',
        userLevelName: '知识进士',
        userLevelImg: '../../../images/paihang_levelImg1.png',
        userStart: 8
      },
      {
        rankNum: 4,
        headImg: '../../../images/user_img.png',
        nickname: '沉浮',
        userfrom: '莆田',
        userLevelName: '知识进士',
        userLevelImg: '../../../images/paihang_levelImg1.png',
        userStart: 7
      }
    ],
    globalArr: [
      {
        rankNum: 1,
        headImg: '../../../images/user_img.png',
        nickname: '飞花',
        userfrom: '澳大利亚',
        userLevelName: '知识状元',
        userLevelImg: '../../../images/paihang_levelImg2.png',
        userStart: 10
      },
      {
        rankNum: 2,
        headImg: '../../../images/user_img.png',
        nickname: '飞非',
        userfrom: '德国',
        userLevelName: '知识状元',
        userLevelImg: '../../../images/paihang_levelImg2.png',
        userStart: 9
      },
      {
        rankNum: 3,
        headImg: '../../../images/user_img.png',
        nickname: '飞画',
        userfrom: '意大利',
        userLevelName: '知识状元',
        userLevelImg: '../../../images/paihang_levelImg2.png',
        userStart: 8
      },
      {
        rankNum: 4,
        headImg: '../../../images/user_img.png',
        nickname: '飞雾',
        userfrom: '新西兰',
        userLevelName: '知识状元',
        userLevelImg: '../../../images/paihang_levelImg2.png',
        userStart: 7
      }
    ]
  },
  rankingListTab: function (event) {
    let id = event.target.dataset.id;
    if(id == '1') {
      this.setData({ showTit: true })
    } else {
      this.setData({ showTit: false })
    }
    // console.log(event);
    // console.log(this.data);
  },
  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {
  
  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {
  
  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {
  
  },

  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {
  
  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {
  
  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {
  
  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {
  
  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {
  
  }
})